perm filename WHO.ME[UP,DOC] blob sn#437069 filedate 1979-05-02 generic text, type C, neo UTF8
COMMENT ⊗   VALID 00002 PAGES
C REC  PAGE   DESCRIPTION
C00001 00001
C00002 00002	The WHO command (abbreviated W) runs the WHO program, which presents
C00024 ENDMK
C⊗;
The WHO command (abbreviated W) runs the WHO program, which presents
system status information at your terminal.  If you are at a Data
Disc or III display terminal, the information is displayed and
continually updated as long as the program continues to run.  If you
are not at a display, the information is typed out once.  The WHO
monitor command does not require that you be logged in.

There are several commands which can be given to WHO to tell it what
information to present; these WHO commands are listed at the end of
this writeup.  On non-displays, WHO commands can only be given in the
monitor command line that runs WHO.  On displays, WHO commands can be
included in the monitor command running WHO and/or can be given
directly to WHO after it has started.  For example, the monitor
command line "WHO R<cr>" can be given at any terminal.	In a monitor
command line, any WHO command taking an argument (@*+-") must be the
last thing in the line (hence there can be only one such
argument-taking command in the monitor command line).  Any characters
in the monitor command line which are not legal WHO commands are
ignored.  Note that the character ";" is a WHO command (same as "↑")
and is NOT interpreted by WHO as delimiting a comment in the monitor
command line.

From any terminal, the REENTER monitor command given with WHO will
cause the information to be sent to the line printer (LPT) instead of
to the terminal.  The information printed will be an updated version
of the information last typed out or displayed, or the complete set
of information if you have not yet started WHO; on displays, the
whole picture is printed, not just the part that fits on the screen.


The first part of the WHO display is a list of the jobs on the
system, with various information about each job.  This list is
divided into two sections, for jobs belonging to users and for system
phantom jobs.  (More precisely, the second section contains jobs
which are detached and have the JLOG bit off in the job status word,
i.e., are not logged in.)  Jobs attached to pseudo-teletypes are
listed under the controlling job, with the line for the controlled
job indented.  The listing for each job has several parts:

  JOB	   job number
  QUEUE    queue name, as in the WHO line, with possibly an extra
	   character meaning one of several states (if more than one
	   applies, the one listed first below is displayed):
	   ←  the job is in the JBTSIN list of jobs needed in core
	   -  the job is now actually running
	   ⊗  the job is locked in core
	   →  the job's upper segment is about to be swapped in
	   ↑  the job is next in line to be swapped out
	   ↓  the job is next in line to be swapped in
	   *  the job is swapped out
  PPN	   the job's logged-in PPN
	   (This will be 100100 for not-logged-in WHOs, etc.)
  TV	   the Data Disc TV number where the job is being controlled
  LINE	   the job's terminal line number, or DET for detached jobs
  JOBNAM   the job name
  SIZE	   the job's core image size in K (1024-word blocks)
  TIME	   the job's total run time since login
  PL	   percentage of CPU time spent on this job recently
  SL	   service level reservation for this programmer
  SEG	   job number of this job's upper segment, if any
  SWR	   number of ticks between startups of job's KL-10
	   spacewar module, if any
  ALIAS    the job's ALIAS PPN, if any


After the job display comes the information for upper segments,
containing the job number (possibly followed by one of the above
single-character markers), a "W" if the segment is not write
protected, the segment's job name, its core size, and the number of
jobs attached to the segment.


The next part of the WHO display is a summary of overall system
statistics.  This includes: UPTIME--the time since the system was
last restarted; NULTIMES--short and long term time spent running the
null job; WASTED--short and long term time spent running the null job
when another job wanted to be run but wasn't in core; CORE--total
user core image sizes in core and swapped out; USABLE--the largest
contiguous free block of core, the total available user core not used
by locked-in jobs, and the total available user core; RUNNING
JOBS--the number of jobs in RUNQ and TQ and their combined core image
size; and TOTAL SLEVEL--the total service level reservation for
logged-in users.


The final section of the WHO display is a list of all I/O devices in
use by programs or assigned by jobs.  For each such use of a device,
a line is displayed containing: the device's logical name, if any;
the device's physical name; the character "#" if the device was
assigned by the ASSIGN command; the number of the job using the
device; if a particular file is open, the file name, extension, and
directory ppn (for disk files), the number of records in the file,
the record currently being read or written, and the read/write status
of the file.  This last will be W if the file is open for output, R
if open for input, or RA if open in read-alter mode, followed by E if
the end of file has been read.	Note: if the file has been closed,
there may be no mode flags, and the number 1101 will appear in the
current-record position.  Record numbers are displayed in octal.


			WHO COMMANDS

WHO accepts commands to determine what information is to be
presented.  These are single-character commands that should not be
followed by carriage return.  Some of these commands, however, must
be followed by an argument ended with a carriage return; ending such
an argument with an altmode will abort the command.

On display terminals, only part of the information can fit on the
screen at a given time.  Certain commands provide "scrolling" of the
display up or down; these commands are ignored on non-displays.

The available commands are listed in the table below.  Other
characters will be ignored if appearing in a monitor command line
that runs WHO, but will make WHO clear the screen and exit if typed
to a WHO running on a display.	If no command is typed to a WHO
running on a display for 2 minutes, WHO will exit unless the "∞"
command (see below) has been given.  After WHO exits, whether by
command, by timing out, or by finishing the output on a TTY or the
LPT, typing the monitor command CONTINUE will cause it to restart and
to continue presenting on the terminal the same information it was
presenting when it exited.

  Q	   This is a legal command only on non-displays.  This causes
	   the typeout to include only the PPN and TTY number for all
	   jobs that are attached to a terminal.  Without the Q, WHO
	   will type out the complete normal list of information
	   described above.
  ↑ (or ;) scroll up 1/2 screen (on displays only)
  ↓ (or :) scroll down 1/2 screen (on displays only)
  FF	   (formfeed) scroll up whole screen (on displays only)
  VT	   (vertical tab) scroll down whole screen (on displays only)
  0-9	   repeat argument for following scrolling command: ↑;↓:FF VT
  ∞ (or \) run longer before automatically stopping; otherwise WHO
	   exits when nothing has been typed in for two minutes (on
	   displays only).  Currently this command makes WHO run
	   unattended for 10 minutes before exiting by itself.
  R	   only display jobs which have recently been Running
	   (not in NULQ, STOP, IOWQ, or INTW)
  N	   restore Normal display (all jobs)
  U	   Update, forces a complete update of a datamedia screen.
  E	   Exit, leaving information displayed on the screen with the
	   page printer set up to avoid erasing it (on displays only)
  T	   Type out the job information only.  This works on all
	   terminals; on displays, it will exit after the typeout.
  F	   Same as T, but devices (F is for Files) are listed also.
	   Both T and F omit the system statistics.
  M V * "  These seven commands allow you to specify which jobs
  + - @    should be displayed.  WHO keeps two special tables of job
	   specifications for deciding which jobs it will display;
	   these tables are called the PLUS table and the MINUS
	   table.  Jobs specified by the MINUS table will not be
	   displayed (regardless of other conditions).	The PLUS
	   table is ignored if empty; but if it is non-empty, then
	   only jobs specified by the PLUS table are displayed;
	   however, jobs specified by both tables will NOT be
	   displayed, since the MINUS table has priority.  Both
	   tables are initially empty and the R and N commands reset
	   both tables to empty.  Jobs can be specified in these
	   tables by project name, programmer name, project name and
	   programmer name, job number, and job name.  Each of the
	   commands * + - " @ takes an argument which should be ended
	   with a carriage return; if an argument is ended with an
	   altmode, the command will be aborted.  WHO will beep you
	   if an argument is not accepted (illegal argument or
	   aborted with altmode.)  The commands M and V take no
	   argument.  The argument to @ is a filename, the argument
	   to " is a job name, and the argument to each of the
	   commands * + - is a job specification which can be any of
	   the following forms:
	     PRG      programmer name (letters and digits only)
	     ,PRG     programmer name (letters and digits only)
	     PRJ,     project name (letters and digits only)
	     PRJ,PRG  project-programmer name (letters & digits only)
	     NUMBER   a decimal job number less than 64 (digits only)
	     "NAME    a job name (any sixbit characters after ")
	   A job will match specifications of the first four types if
	   either its logged-in PPN or its ALIAS PPN matches the
	   specification.  Any job running on a PTY owned by a job
	   being displayed will also be displayed, unless the job on
	   the PTY matches a specification in the MINUS table.	If a
	   job running on a PTY is displayed and its controlling job
	   is not displayed, then the job on the PTY will be indented
	   using dots (.'s) instead of spaces (which would be used if
	   the controlling job were being displayed).

	   The seven individual commands are described below.

  M	   only display jobs matching your logged-in programmer name
	   or your ALIAS programmer name (clears both tables and then
	   puts your logged-in programmer name and your ALIAS
	   programmer name into PLUS table)
  V	   only display jobs belonging to volleyball players
	   (simulates an @VB.DIS[P,DOC]--see @ below)
  *<spec>  only display jobs matching the specification <spec>
	   (clears both tables and then puts <spec> into PLUS table)
  +<spec>  also display jobs matching <spec> except those matching
	   entries in MINUS table (adds <spec> to PLUS table and re-
	   moves it from MINUS table; leaves running-jobs-only mode)
  -<spec>  don't display jobs matching <spec> (adds <spec> to MINUS
	   table and removes it from PLUS table)
  "<name>  only display jobs with the job name <name>
	   (clears both tables and then puts <name> into PLUS table)
  @<file>  clear PLUS & MINUS tables and then put job specifications
	   from the file <file> into the tables.  E directory pages
	   and SOS line numbers are permitted and ignored.  The
	   default extension .DIS is used if no extension is typed.
	   If no PPN is typed, the disk area [P,DOC] is tried first,
	   then your own disk area, to find the file.

	   In reading from a file:

	   1) Spaces are ignored except in job names.
	   2) A semicolon (;) not appearing in a job name causes the
	   rest of the line to be ignored.
	   3) Non-sixbit characters (except lower-case letters, which
	   are converted to upper case) are treated just like CRLFs.

	   An entry in the file can be any of the forms listed below,
	   and should be terminated by a comma or a CRLF.  Note
	   however that a comma (or any other sixbit character
	   including semicolon and space) appearing as one of the
	   first 6 characters of a job name will be taken as part of
	   the job name.
	     +<specx>	Add the specification <specx> to PLUS table.
	     <specx>	Add the specification <specx> to PLUS tabls.
	     -<specx>	Add the specification <specx> to MINUS table.
	   Unless all entries in the file are of the form -<specx>,
	   WHO leaves running-jobs-only mode (R).  A job
	   specification in a file, <specx>, can be any of the
	   following forms (note that these are slightly different
	   from the forms for <spec> that you can type in):
	     PRG	programmer name
	     [PRG]	programmer name
	     [,PRG]	programmer name
	     [PRJ,]	project name
	     [PRJ,PRG]	project-programmer name
	     "NAME	job name.  After the " the first 6 characters
			(or less if terminated by a CRLF) are taken
			as a job name.	Then characters are skipped
			until a comma or CRLF is seen.
	   Note that you cannot specify a job number from a file.

∂2 May 79 -- ME  	WHO
Four new commands have been added to the WHO program.  They are:
	D	Devices -- display only the Devices (e.g., files) open
	J	Jobs -- display Jobs (undoes D command) as well as devices
	O	Omit statistics (uptime, null time, etc.) from display
	I	Include stats (undoes O command)
Both D and J restore the position of the window back to the top of the
currently selected text.  All of these commands are orthogonal to the
commands that select which jobs to display.  For example, if you want
to see only files open for volleyball players, you can say WHO VD.